package cmd

import (
	"fmt"

	"gitee.com/workits/pkgs/toolx"
	"github.com/spf13/cobra"
)

var addComp string

var addCmd = &cobra.Command{
	Use:   "add",
	Short: "安装组件(暂时无用)",
	Long:  "安装组件(暂时无用)",
	Run: func(cmd *cobra.Command, args []string) {
		toolx.NewComponent(".", addComp)

		fmt.Println("🎉组件安装完成")
	},
}

func init() {
	rootCmd.AddCommand(addCmd)
	addCmd.Flags().StringVarP(&addComp, "compnent", "c", "http", "组件名称")
}
